package com.ls.pay.repository;

import com.ls.pay.pojo.Recharge;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

/**
 * @author 钰杰
 * @className RechargeRrepository
 * @description VX:FengYJ996
 * @date 2020/1/720:52
 */
public interface RechargeRrepository extends JpaRepository<Recharge,Integer> {

    Recharge findByOutTradeNo(String out_trade_no);

    @Query(nativeQuery = true,value = "SELECT * FROM tb_recharge WHERE out_trade_no = ?1")
    Recharge findByTradeno(String trade_no);
}

